import React, { Component } from 'react'
import A from './components/A'
import B from './components/B'

export default class App extends Component {
  state = {
    count: 0
  }
  changeCount = (count) => {
    this.setState({
      count: this.state.count + count
    })
  }
  render () {
    return (

      <>
        <A changeCount={this.changeCount} />
        <B count={this.state.count} />
      </>

    )
  }
}
